<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>业主爱家</title>
<link type="text/css" rel="stylesheet" href="css/houseMain.css">
<link rel="stylesheet" href="css/normalize.css">
<link rel="stylesheet" href="css/style.css" media="screen"
	type="text/css" />
<script type="text/javascript">
$(function(){
	var flag=true;
	  $("#userName").blur(function(){
		  var userName=$(this).val();
		  if(userName=="" || userName ==null ){
			  $("#tips").text("用户名不为空"); 
			  flag=false;
		  }
	  })
	    $("#password").blur(function(){
	    	  var name=$(this).val();
	    	  if(name=="" || name ==null){
				  $("#tipwd").text("该项是必填项！");
				  flag=false;
	    	  }
	    })
	    $("#rpassword").blur(function(){
	    	  var $pwd = $("#rpassword").val();
	           var $divID = $("#password").val();
	             if($pwd=="" || $pwd ==null){
					  $("#tirpwd").text("该项是必填项！");
					  flag=false;
		    	  }else{
		    		  if ($pwd == $divID) {
		    			  $("#tirpwd").text("");  
		    			 
			           }else{
			        	   $("#tirpwd").text("密码不一致！");
			        	   flag=false;
			           } 
		    	  }
	    })
	     $("#email").blur(function () {
               var ee=$(this).val();
               if(ee=="" || ee ==null){
                   $("#tiemail").text("邮箱不能为空！");
                   flag=false;
               }else{
               if(0<ee.indexOf('@')+1<ee.indexOf('.')){
                   $("#tiemail").text("")
                  
               }
               else {
                   $("#tiemail").text("邮箱格式不对！");
                   flag=false;
               }
               }
           })
})
</script>
</head>
<body style="width: 100%;">
	<div id="content">
		<div id="conTitle">&nbsp;| 修改物管信息</div>
		<div id="updateManager">
			<form action="updateUser" method="post">
				<table>
					<tr>
						<td>用户名:</td>
						<td><input type="text" value="${list[0].userName}"
							id="userName" name="userName" /></td>
						<td><div id="tips"></div></td>						
					</tr>
					<tr>
						<td>密码:</td>
						<td><input type="password" value="${list[0].password}"
							id="password" name="password"/></td>
						<td><div id="tipwd"></div></td>
					</tr>
					<tr>
						<td>确认密码:</td>
						<td><input type="password" value="${list[0].password}"
							id="rpassword" /></td>
						<td><div id="tirpwd"></div></td>
					</tr>
					<tr>
						<td>邮箱地址:</td>
						<td><input type="text" value="${list[0].email}" id="email" name="email"/></td>
						<td><div id="tiemail"></div></td>
					</tr>
					<tr>
						<td><input type="submit" value="确定" /></td>
						<td><input type="button" value="取消"
							onclick="window.history.go(-1)" /></td>
					</tr>
				</table>
			</form>
		</div>
	</div>
</body>
</html>